const asyncGetRouter = {
    namespaced: true,
    state: () => ({ 
        dynamicRoute: []
    }),
    mutations: {
        getRoute(state, RouteArrar) {
            state.dynamicRoute = RouteArrar
        }
    },
    actions: {
        setAsyncAddRoute(context, RouteArrar) {
            localStorage.setItem('dynamicRoute',JSON.stringify(RouteArrar))
            context.commit('getRoute', RouteArrar)
            return Promise.resolve(RouteArrar)
        }
    },
}

export default asyncGetRouter